package com.example.demo.testOne;

import cn.hutool.core.util.RandomUtil;
import cn.hutool.core.util.StrUtil;

import java.util.Arrays;
import java.util.List;

/**
 * @description
 *
 * @author lilinchun
 * @date 2024/01/02
 */
public class demo22 {

    public static void main(String[] args) {
        List<String> list= Arrays.asList("1","2","3","4","5","6","7");
        String s = RandomUtil.randomEle(list);

        String avatar = StrUtil.blankToDefault("10", s);
        for (int i = 0; i < list.size(); i++) {
            System.out.println(avatar);
        }

        list.forEach(x->{
            if(StrUtil.equals("1",x)){
                x="10";
            }
        });

        System.out.println();
        String i="1";
        String b="2";
        if(StrUtil.isAllBlank(i,b)){
            System.out.print("13456");
        }

    }
}
